package com.bruce.starts.demo.designpattern.composite;

public abstract class FileSystemNode {
    protected String path;

    public FileSystemNode(String path) {
        this.path = path;
    }

    public abstract int countNumOfFiles();
    public abstract long countSizeOfFiles();
    public void print(){
        throw new UnsupportedOperationException("不支持的操作");
    }
    public String getName(){
        throw new UnsupportedOperationException("不支持的操作");
    }
    public void add(FileSystemNode node){
        throw new UnsupportedOperationException("不支持的操作");
    }
    public void remove(FileSystemNode node){
        throw new UnsupportedOperationException("不支持的操作");
    }

    public String getPath() {
        return path;
    }
}
